<include file="public@header" />
</head>
<body>
	<div class="wrap js-check-wrap">
		<ul class="nav nav-tabs">
			<li class="active"><a href="">医生信息列表</a></li>
			<li><a href="{:url('Doctor/create')}">新增医生</a></li>
		</ul>
		<table class="table table-hover table-bordered">
			<thead>
				<tr>
					<th>ID</th>
					<th>姓名</th>
					<th>简介</th>
					<th>头像</th>
					<th>二维码</th>
					<th>擅长领域</th>
					<th>每日预约上限</th>
					<th>操作</th>
				</tr>
			</thead>
			<tbody>
				<empty name="data">
					<tr><td class="text-center" colspan="12">暂无任何数据！</td></tr>
					<else/>
					<foreach name="data" item="v">
						<tr>
							<td>{$v.d_id}</td>
							<td>{$v.d_name}</td>
							<td>{$v.d_desc}</td>
							<td><img src="/upload/{$v.d_head}" width="80px;"></td>
							<td><img src="/upload/{$v.d_erwei}" width="80px;"></td>
							<td>{$v.d_shanchang}</td>
							<th>{$v.d_topnum}</th>
							<td>
							<a href="{:url('Doctor/edit',['id'=>$v.d_id])}" class="btn btn-primary btn-xs">修改</a>
								<a href="{:url('Doctor/delete',['id'=>$v.d_id])}" class="btn btn-danger btn-xs js-ajax-delete">删除</a>
							</td>
						</tr>
					</foreach>
				</empty>
			</tbody>
		</table>
		<div class="pagination">{$page}</div>
	</div>
	<script src="__STATIC__/js/admin.js"></script>
	<script src="__STATIC__/js/layer/layer.js"></script>
	<script>
		$(".info").click(function(e){
		    let id = $(e.target).attr("data-id");
		    layer.open({
				type:2,
				title:"预约信息",
				area:['600px',"80%"],
				content:"{:url('Order/read')}?id="+id
			});
		});
		$(".info2").click(function(e){
		    let id = $(e.target).attr("data-id");
		    layer.open({
				type:2,
				title:"问诊单信息",
				area:['450px',"80%"],
				content:"{:url('Order/wenzhen')}?id="+id
			});
		});

	</script>
</body>
</html>
